const rules = {
	name: [{
		required: true,
		message: '请输入用户姓名',
		trigger: ['change', 'blur']
	}],
	head_image: [{
		required: false,
		message: '请上传用户头像',
		trigger: ['change', 'blur']
	}],
}
const examineStatus = [{
		name: '未审核',
		value: 0,
		disabled: false,
	},
	{
		name: '审核通过',
		value: 1,
		disabled: false
	},
	{
		name: '审核拒绝',
		value: 2,
		disabled: false
	}
]
const status = [{
		name: '正常',
		value: 0,
		disabled: false,
	},
	{
		name: '冻结',
		value: 1,
		disabled: false
	},
]
const conformTerm = [{
		name: '未确认',
		value: 0,
		disabled: false
	},
	{
		name: '已确认',
		value: 1,
		disabled: false
	},
]
const isTechnician = [{
		name: '否',
		value: 0,
		disabled: false
	},
	{
		name: '是',
		value: 1,
		disabled: false
	},
]
const orderTaking = [{
		name: '可接单',
		value: 0,
		disabled: false
	},
	{
		name: '进行中',
		value: 1,
		disabled: false
	},
]
let form = {
	"head_image": "",
	"name": "",
	"sex": "",
	"mobile": "",
	"birthday": "",
	"id_card": {
		"card_zheng": "",
		"card_fan": "",
		"card_id": ""
	},
	"shop": {
		title:'',
	},
	"classify": {
		"_id": ''
	},
	"location": {
		_id: '',
		text: ''
	},
	"money": 0,
	"orders": 0,
	"sell": 0,
	"collect": 0,
	"comment": {
		"number": 0,
		"text": ''
	},
	"coordinate": {},
	"examine_status": {
		"text": '审核通过',
		"value": 1,
		"datetime": Date.now()
	},
	"status": {
		"value": 0,
		"text": '正常'
	},
	"create_date": {},
	"order_taking": {
		"value": 0,
		"time": 0
	},
}
/**
 * 根据步骤值返回相应的提示信息
 * @param {number} step - 步骤值
 * @returns {string} - 相应的提示信息
 */
const onStepValue = (step) => {
	switch (step) {
		case 0:
			return '未填写任何资料'
			break;
		case 1:
			return '实名认证'
			break;
		case 2:
			return '上传头像'
			break;
		case 3:
			return '阅读服务条款'
			break;
		default:
			return '未知'
			break;
	}
}
// 审核状态颜色返回
const examStatusColor = (status) => {
	switch (status) {
		case 0:
			return '#ef5352';
			break;
		case 1:
			return '#4cd964';
			break;
		case 2:
			return '#ef5352';
			break;
		default: return '#f0ad4e'
			break;
	}
}
// 订单状态颜色返回
const onStatusColor = (val) => {
	switch (val){
		case 0:return '#777777'
			break;
		case 1:return '#ff3737'
			break;
		case 2:return '#f0ad4e'
			break;
		case 3:return '#24bfee'
			break;
		case 4:return '#4cd964'
			break;
		case 5:return '#4cd964'
			break;
		default: return 'red'
			break;
	}
}

export {
	rules,
	examineStatus,
	status,
	conformTerm,
	form,
	isTechnician,
	orderTaking,
	onStepValue,
	examStatusColor,
	onStatusColor
}